/*
 * Copyright 2008 Federal Emergency Management Agency
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"); 
 * you may not use this file except in compliance with the License. 
 * You may obtain a copy of the License at 
 * 
 *    http://www.apache.org/licenses/LICENSE-2.0 
 *    
 * Unless required by applicable law or agreed to in writing, software 
 * distributed under the License is distributed on an "AS IS" BASIS, 
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and 
 * limitations under the License. 
 *  
 */
package gov.fema.hazus.bdc.shared.entity;

import java.io.Serializable;

import javax.persistence.Entity;
import javax.persistence.Id;

@Entity
public class Economy implements Serializable {
	
	@Id Long id;
	private static final long serialVersionUID = -1004489215213474957L;
	
	private Double buildingValue;
	private String valuationType;
	private Integer valuationYear;
	private Double contentsValue;
	private Double inventoryValue;
	private Double rentalIncomePerMonth;
	private Double businessIncomePerDay;
	private Double wagesPerDay;
	
	// constants for listeners
	public static final String BUILDINGVALUE = "building value";
	public static final String VALUATIONTYPE = "valuation type";
	public static final String VALUATIONYEAR = "valuation year";
	public static final String CONTENTSVALUE = "contents value";
	public static final String INVENTORYVALUE = "inventory value";
	public static final String RENTALINCOME = "rental income";
	public static final String BUSINESSINCOME = "business income";
	public static final String WAGESPERDAY = "wages per day";
	
	public Economy()
	{
		buildingValue = 0.0;
		valuationYear = 0;
		contentsValue = 0.0;
		inventoryValue = 0.0;
		rentalIncomePerMonth = 0.0;
		businessIncomePerDay = 0.0;
		wagesPerDay = 0.0;
	}



	public Double getBuildingValue() {
		return buildingValue;
	}



	public void setBuildingValue(Double buildingValue) {
		this.buildingValue = buildingValue;
	}



	public String getValuationType() {
		return valuationType;
	}



	public void setValuationType(String valuationType) {
		this.valuationType = valuationType;
	}



	public Integer getValuationYear() {
		return valuationYear;
	}



	public void setValuationYear(Integer valuationYear) {
		this.valuationYear = valuationYear;
	}



	public Double getContentsValue() {
		return contentsValue;
	}



	public void setContentsValue(Double contentsValue) {
		this.contentsValue = contentsValue;
	}



	public Double getInventoryValue() {
		return inventoryValue;
	}



	public void setInventoryValue(Double inventoryValue) {
		this.inventoryValue = inventoryValue;
	}



	public Double getRentalIncomePerMonth() {
		return rentalIncomePerMonth;
	}



	public void setRentalIncomePerMonth(Double rentalIncomePerMonth) {
		this.rentalIncomePerMonth = rentalIncomePerMonth;
	}



	public Double getBusinessIncomePerDay() {
		return businessIncomePerDay;
	}



	public void setBusinessIncomePerDay(Double businessIncomePerDay) {
		this.businessIncomePerDay = businessIncomePerDay;
	}



	public Double getWagesPerDay() {
		return wagesPerDay;
	}



	public void setWagesPerDay(Double wagesPerDay) {
		this.wagesPerDay = wagesPerDay;
	}



	public String toString()
	{
		String str = "";
		str += "[economy";
		str += "[building-value="+this.buildingValue+"]";
		str += "[valuation-type="+this.valuationType+"]";
		str += "[valuation-year="+this.valuationYear+"]";
		str += "[contents-value="+this.contentsValue+"]";
		str += "[inventory-value="+this.inventoryValue+"]";
		str += "[rental-per-month="+this.rentalIncomePerMonth+"]";
		str += "[business-income-per-day="+this.businessIncomePerDay+"]";
		str += "[wages-per-day="+this.wagesPerDay+"]";
		str += "]";
		return str;
	}



	public Long getId() {
		return id;
	}



	public void setId(Long id) {
		this.id = id;
	}
}
